<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>后台商品添加</title>
</head>
<body>
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <form action="doAdd" class="form-horizontal m" id="form-biProduct-add" method="post">
        <div class="form-group">
            <label class="col-sm-3 control-label">分类：</label>
            <div class="col-sm-8">
                <input id="categoryId" name="categoryId" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">主图：</label>
            <div class="col-sm-8">
                <input id="mainImg" name="mainImg" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">商品名称：</label>
            <div class="col-sm-8">
                <input id="productName" name="productName" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">建议价格：</label>
            <div class="col-sm-8">
                <input id="suggestPrice" name="suggestPrice" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">价格：</label>
            <div class="col-sm-8">
                <input id="price" name="price" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">模型，json格式保存：</label>
            <div class="col-sm-8">
                <input id="model" name="model" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">存货量：</label>
            <div class="col-sm-8">
                <input id="stock" name="stock" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">介绍：</label>
            <div class="col-sm-8">
                <input id="description" name="description" class="form-control" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">销量：</label>
            <div class="col-sm-8">
                <input id="salesCount" name="salesCount" class="form-control" type="text">
            </div>
        </div>
        <button type="submit">提交</button>
    </form>
</div>
<script type="text/javascript">
    var prefix = ctx + "system/biProduct"
    $("#form-biProduct-add").validate({
        rules:{
            xxxx:{
                required:true,
            },
        },
        focusCleanup: true
    });

    function submitHandler() {
        if ($.validate.form()) {
            $.operate.save(prefix + "/add", $('#form-biProduct-add').serialize());
        }
    }
</script>


</body>
</html>